package com.dfd.mango.admin.service;

import com.dfd.mango.admin.entity.SysCaptcha;

import java.awt.image.BufferedImage;

/**
 * 验证码
 */
public interface SysCaptchaService {
    /**
     * 生成验证码
     * @param uuid
     * @return
     */
    BufferedImage getCaptcha(String uuid);

    int deleteByPrimaryKey(String uuid);

    int insert(SysCaptcha record);

    int insertSelective(SysCaptcha record);

    SysCaptcha selectByPrimaryKey(String uuid);

    int updateByPrimaryKeySelective(SysCaptcha record);

    int updateByPrimaryKey(SysCaptcha record);

    /**
     * 校验验证码
     * @param uuid
     * @param captcha
     * @return
     */
    boolean validate(String uuid, String captcha);

    boolean deleteCaptcha();
}

